package xyz.chaobei.thread.wait;

import com.sun.corba.se.impl.activation.ProcessMonitorThread;

import java.util.ArrayDeque;
import java.util.Queue;

/**
 * @copyright (C), 2015-2020
 * @fileName: Main
 * @author: MRC
 * @date: 2021/1/29 23:22
 * @description:
 */
public class Main {

    public static void main(String[] args) {

        // 共享队列，大小为16
        Queue queue = new ArrayDeque();

        Thread production = new Thread(new ProductionThread(queue),"production1");
        Thread customer = new Thread(new CustomerThread(queue),"customer1");

        production.start();
        customer.start();
    }

}
